import subprocess
res = subprocess.run(['cd'], shell=True, check=True, capture_output=True, text=True)
print(res)